var mySwiper = new Swiper('.swiper-container', {
	loop: true,
	autoplay: 3000,
	autoplayDisableOnInteraction: false,
	pagination: '.swiper-pagination',
	paginationClickable: true
});
$(window).scroll(function() {
	var scroll = $(window).scrollTop();
	var height = window.pageYOffset;
	var gao = scroll + height;
	//关于图标
	var height_status = $(".status_photo").offset().top + $(".status_photo").height() / 2;
	if(gao > height_status) {
		$(".status_photo img").addClass("animated bounceIn");
		setTimeout(function() {
			$(".status_photo span").addClass("animated flip")
		}, 1000)
	}
	//关于人才缺口
	var height1 = $(".rare_content").offset().top + $(".rare_content").height() / 2;
	var height2 = $(".rare_content3").offset().top + $(".rare_content").height();
	if(gao > height1) {
		$(".rare_content1 .rare_left").addClass("animated bounceInLeft");
		$(".rare_content2 .rare_right").addClass("animated bounceInRight");
		setTimeout(function() {
			$(".rare_content1 .rare_right").addClass("animated bounceInRight");
			$(".rare_content2 .rare_left").addClass("animated bounceInLeft");
		}, 1000)
	}
	if(gao > height2) {
		$(".rare_content3 .rare_left").addClass("animated bounceInLeft");
		$(".rare_content4 .rare_right").addClass("animated bounceInRight");
		setTimeout(function() {
			$(".rare_content3 .rare_right").addClass("animated bounceInRight");
			$(".rare_content4 .rare_left").addClass("animated bounceInLeft");
		}, 1000)
	}
	//热门企业
	var height_hot = $(".hot_container").offset().top + $(".hot_container").height() / 2;
	if(gao > height_hot) {
		$(".hot_container").addClass("animated fadeInDown")
		setTimeout(function() {
			$(".hot_vocation span:last-child").addClass("animated fadeInUp");
			$(".hot_vocation span:first-child").addClass("animated fadeInLeft");
			$(".hot_vocation span:nth-of-type(2)").addClass("animated fadeInLeft");
			$(".hot_vocation span:nth-of-type(3)").addClass("animated fadeInUp");
			$(".hot_vocation span:nth-of-type(4)").addClass("animated fadeInRight");
			$(".hot_vocation span:nth-of-type(5)").addClass("animated fadeInRight");
			$(".hot_vocation span:nth-of-type(6)").addClass("animated fadeInDown");
			$(".hot_vocation span:nth-of-type(7)").addClass("animated fadeInDown");
			$(".hot_vocation span:nth-of-type(8)").addClass("animated fadeInLeft");
		}, 1000)
	}
	//课程
	var height_course = $(".course span").offset().top + $(".course span").height();
	var heightCourse = $(".course table").offset().top + $(".course table").height();
	if(gao > height_course) {
		$(".course span").addClass("animated fadeInDown");
	}
	if(gao > heightCourse) {
		$("table").addClass("animated zoomIn")
	}
	//服务
	var height_service = $(".service_container").offset().top + $(".service_container").height();
	if(gao > height_service) {
		$(".service_container img").addClass("animated rotateIn");
		setTimeout(function() {
			$(".service_info").addClass("animated zoomIn");
			$(".service div:nth-of-type(2)").addClass("animated fadeInLeft");
			$(".service_blue").addClass("animated fadeInUp");
			$(".service_yellow").addClass("animated fadeInUp");
			$(".service_green").addClass("animated fadeInRight");
		}, 2000)
	}
	//师资团队
	var height_team = $(".team_container .team_title").offset().top + $(".team_title").height();
	var heightTeam = $(".team_container .team_content").offset().top + $(".team_container .team_content").height();
	if(gao > height_team) {
		setTimeout(function() {
			$(".team_container .team_title").addClass("animated fadeInDown");
		}, 1000)

	}

	if(gao > heightTeam) {
		setTimeout(function() {
			$(".team_container div").addClass("animated bounceInLeft");
		}, 2000)

	}
	//明星学院
	var height_star = $(".star_container .team_title").offset().top + $(".team_title").height();
	var heightStar = $(".star_container .team_content").offset().top + $(".star_container .team_content").height();
	if(gao > height_star) {
		setTimeout(function() {
			$(".star_container .team_title").addClass("animated fadeInDown");
		}, 3000)

	}

	if(gao > heightStar) {
		setTimeout(function() {
			$(".star_container div").addClass("animated bounceInRight");
		}, 3500)

	}
	//证书
	var height_diploma = $(".diploma_content .team_title").offset().top + $(".team_title").height();

	var heightDiploma = $(".diploma_container").offset().top + $(".diploma_container").height();
	if(gao > height_diploma) {
		setTimeout(function() {
			$(".diploma_container .team_title").addClass("animated fadeInDown");
		}, 4000)

	}

	if(gao > heightDiploma) {
		setTimeout(function() {
			$(".diploma_container img").addClass("animated zoomIn");
		}, 5000)

	}
	//合作伙伴
	var height_community = $(".community_container .team_title").offset().top + $(".team_title").height();

	var heightCommunity = $(".community_content").offset().top + $(".community_content").height();
	if(gao > height_community) {
		setTimeout(function() {
			$(".community_container .team_title").addClass("animated fadeInDown");
		}, 6000)

	}

	if(gao > heightCommunity) {
		setTimeout(function() {
			$(".community_content div").addClass("animated bounceInLeft");
		}, 7000)

	}
	//  赚多少
	var height_money = $(".money_container").offset().top + $(".money_container").height() / 2;

	if(gao > height_money) {
		setTimeout(function() {
			$(".money_content").addClass("animated fadeInDown");
		}, 7000)
	}
	//底部
	var height_foot = $(".foot_container").offset().top + $(".foot_container").height() / 2;
	if(gao > height_foot) {
		setTimeout(function() {
			$(".foot_left").addClass("animated slideInDown");
			$(".foot_right").addClass("animated slideInDown");
		}, 8000)
	}
	var height_footer = $(".footer_container").offset().top + $(".footer_container").height() / 2;

	if(gao > height_footer) {
		setTimeout(function() {
			$(".footer_left").addClass("animated rollIn");
			$(".footer_right").addClass("animated rollIn");
		}, 8000)
	}
})
function change(){
	var h = $("header").height()-10;
	$(".icon").css("top", h);
}
change();
window.onresize = function() {
	change();
}
$(".team_message").hover(function() {
	$(this).animate({
		'opacity': '0.5'
	}, 300)
}, function() {
	$(this).animate({
		'opacity': '1'
	}, 300)
})